Unified common coding methods and Java Web Coding
Unified format: (UTF-8 is not required, but must be unified)
JSP:
Servlet:
Request. setCharacterEncoding ("UTF-8"); // set the input encoding format.
Response. setContentType ("text/html; charsetType = gb2312"); // you can specify the output encoding format.
Database :/? UserUnicode = true characterE
Coding has always been a headache for the novice, especially GBK, GB2312, UTF-8 the three more common differences in the page encoding, but also let many novice disoriented, how to explain the explanation is not clear. But coding is so important, especially in this piece of Web page. If you call out is not garbled, and the We
Reprint: http://www.qianxingzhem.com/post-1499.htmlWeb page coding that's the thing.Coding has always been a headache for the novice, especially GBK, GB2312, UTF-8 the three more common differences in the page encoding, but also let many novice disoriented, how to explain the explanation is not clear. But coding is so important, especially in this piece of Web pa
Source: Stalker M. 's BlogCoding has always been a headache for the novice, especially GBK, GB2312, UTF-8 the three more common differences in the page encoding, but also let many novice disoriented, how to explain the explanation is not clear. But coding is so important, especially in this piece of Web page. If you call out is not garbled, and the Web page garbl
This article on the use of Emmet more detailed, so I collected ~ ~ ~Reprint: Web front end developer-web Front end Engineer» Accelerate web front-end development with Emmet (formerly Zen Coding)Formerly known as Zen Coding, the Emmet plugin is a plug-in for a text editor tha
I. Coding and decoding involved in the Java Web
We all know that for Chinese, where I/O is involved in coding, I have already mentioned I/O operations can cause coding, and most I/O generated garbled is network I/O, since almost all applications now involve network operations, and data is transmitted over the network i
last link in the download page: Zen coding for
Web page Shortcut key Description: Ctrl + E: Expand Code CTRL + D: Outward Quick Select block SHIFT + CTRL + D: To quickly select the code block SHIFT + CTRL + A: Enter an abbreviation, automatically expand and surround the selected code CTRL + alt+→: Cursor Smart jump to next edit point (you'll know how thoughtful you are) CTRL + alt+←: Cursor smart jump to
, developers will code for different browsers, which is CSS hack. However, if the developer is coding, it can be noted that the code for which version of the browser is written, will be very convenient for future maintenance work. Here's a good example:
NBSP;NBSP;
14. Avoid excessive annotationAs a developer, adding comments to your code is a good habit, easy to understand an
Simple coding, publishing, and deployment of Web Service (C # instance), webservice
Recently, the boss is preparing to make the communication part of the existing C/S architecture project universal. He needs to support WebService to pave the way for the future B/S architecture upgrade, for this reason, I went to a variety of Baidu WebService tools, and gradually set up a simple WebService. By the way, I le
Parsing Web Development Coding issuesurl:http://tcking.javaeye.com/blog/726643In the Web development time often encounter garbled problem, garbled generally appear now:1. The Chinese in the JSP file becomes garbled2. The Chinese on the page becomes garbled3. Backstage through Request.getparameter () garbledBasic knowledge of codingA computer can store and transfe
Then the idea of the previous section said that a webpage to be able to display correctly in the browser, you need to maintain the same code in three places: Web page file, Web page encoding declaration and browser coding settings.
The first is the encoding of the page file itself, that is, what code is used to save the Web
;legend>Personal particularlegend>label for= "Name">Namelabel>inputtype= "text"ID= "Name"name= "Name" />label for= "Email">E-Maillabel>inputtype= "text"ID= "Email"name= "Email" />label for= "Subject">Subjectlabel>inputtype= "text"ID= "Subject"name= "Subject" />label for= "message" >Message Bodylabel> textarearows= "Ten"cols= " the"ID= "message"name= "message" >textarea>fieldset>13, the browser-compatible code to identify information and separate from each otherCross-browser compatibility is a
Recently, we have been studying the attack and defense of XSS, especially Dom XSS, and the problem is slowly migrating to the browser encoding and decoding order.Today was put pigeons, helpless in KFC looked at two hours of information, suddenly had a sense of enlightened. References are posted first:1. http://www.freebuf.com/articles/web/43285.html2. http://www.freebuf.com/articles/web/10121.html3. http://
Original address: http://www.noupe.com/design/tips-for-coding-and-designing-usable-web-forms.html
Note: About label and tag, in the Chinese are translated into the label, and the following appear in the label, are the label translation, such as "User name" + input box, where the "user name" item in English is a label, agreed to translate as a label
A page form is already the most discussed element in
VariablesAll variables must be declared before use, and the initial value is assigned.6. variable namingThe variable type abbreviation (lower case) + English word (the first letter in upper case) is used.Variables in development basically involve several typesInteger: IDecimal: FCharacter: SBoolean: BDate: dSpecial:I, j, m, n are used in sequence in the cycle;Array with aryPointer p, qTemporary Variable TMP
VII. SQL statements1. SortWhen order is used, try to sort the fields that create indexes
HTML has gone through nearly 20 of the development process. From HTML4 to XHTML to the recently hot HTML5, it has almost witnessed the development of the entire Internet. However, even now, there are many basic concepts and principles that still require a high level of attention from developers. Here are some of the development principles that you should follow.
1, use Div to layout
When developing a Web page, the first thing to
before the question, let's take a look at what is Url,uri and QueryString, as shown in 1:Figure 1:url-uri-querystringURL: is the acronym for the Global Resource Locator, as above localhost: refers to domain (IP or hostname), 8080: is the port Web service is generally 80,8080 is the use of its own test, to avoid and browser port conflicts.ROOT: Is the Contentpath, which is the virtual path, if the Tomcat server object is the Servlet: Is the Servletpath
Web page coding problem, generally divided into two aspects1 is the encoding format of the Web page itself, generally different operating system Web page file access encoding is not the same, but generally speaking, the new Web page file is generally related to the IDE, beca
HTML has gone through nearly 20 of the development process. From HTML4 to XHTML to the most recent fiery HTML5, it has almost witnessed the development of the entire Internet. However, even now, there are many basic concepts and principles that still require the developer to be highly aware. Below, we introduce the development principles that should be followed.1, use Div to layoutWhen developing a Web page, the first thing to consider is to different
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.